# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgname=python2-singledispatch
_pkgname=singledispatch
pkgver=3.4.0.3
pkgrel=5
pkgdesc='This library brings functools.singledispatch from Python 3.4 to Python 2.6-3.3.'
url='https://pypi.org/project/singledispatch/#files'
arch=('any')
license=('MIT')
depends=('python2' 'python2-six')
makedepends=('python2-setuptools')
source=("https://files.pythonhosted.org/packages/source/${_pkgname::1}/$_pkgname/$_pkgname-$pkgver.tar.gz")
sha512sums=('ba065d36092ddee6527be3d7cb777c51c0949855bf6dd0ffb7c25acaedaa35d36fe6dc096587acddcd1e9e54c6ac5f92c196b11f9ee1270cc0c1cf2f410446cf')

build() {
  cd "$_pkgname-$pkgver"

  python2 setup.py build
}

package() {
  cd "$_pkgname-$pkgver"

  python2 setup.py install --root="$pkgdir" --prefix=/usr -O1 --skip-build
}

